package com.ccys.db.vo.app.paymentDetails;

import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Data;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * @Author：XLY
 * @Date：2024/2/4 0004
 */

@Data
public class CheckPromoCodeVo {

    @JsonProperty("booking_id")
    private String bookingId;  //": "fe169523-51fc-4e08-9055-e9c64d977d6a",

    @JsonProperty("booking_code")
    private String bookingCode;  //": "0509030463214",

    @JsonProperty("is_waive_consultation_fee")
    private boolean isWaiveConsultationFee;  //": false,

    @JsonProperty("waive_consultation_fee")
    private BigDecimal waiveConsultationFee;  //": 0,

    @JsonProperty("total_cost_consulation")
    private BigDecimal totalCostConsulation;  //": 25,

    @JsonProperty("total_cost_prescription")
    private BigDecimal totalCostPrescription;  //": 0,

    @JsonProperty("delivery_fee")
    private BigDecimal deliveryFee;  //": 0,

    @JsonProperty("is_surcharge_fee")
    private boolean isSurchargeFee;  //": true,

    @JsonProperty("surcharge_fee")
    private BigDecimal surchargeFee;  //": 25,

    @JsonProperty("practice_fee")
    private BigDecimal practiceFee;  //": 0,

    @JsonProperty("grand_total")
    private BigDecimal grandTotal;  //": 50,

    @JsonProperty("promotion_code")
    private PromotionCodeVo promotionCode;
    private TaxVo tax;

    @JsonProperty("grand_total_payment")
    private BigDecimal grandTotalPayment; // 53.5,

    @JsonProperty("delivery_type")
    private String deliveryType ;  //: "Deliver",

    @JsonProperty("delivery_address")
    private List<DeliveryAddressVo> deliveryAddress;
    private String pharmacy;  //": null,
    private String corporate;  //": null,
    private String subscription;  //": null,
    private String prescription;  //": null



    @Data
    public static class PromotionCodeVo{
        private String id;   //": 4,
        private String name;   //": "11111",
        @JsonProperty("patient_identifier")
        private String patientIdentifier;   //": "Delivery Charge Waived",
        private boolean reusable;   //": true,

        @JsonProperty("limit_number")
        private Integer limitNumber;   //": 0,

        @JsonProperty("used_number")
        private Integer usedNumber;   //": 0,
        private Integer type;   //": 0,
        private BigDecimal amount;   //": 3,

        @JsonProperty("start_date")
        private Date startDate;   //": "2018-10-21T00:00:00",

        @JsonProperty("end_date")
        private Date endDate;   //": "2018-10-31T00:00:00",

        @JsonProperty("is_active")
        private boolean isActive;   //": true,

        @JsonProperty("patient_identifier_value")
        private String patientIdentifierValue;   //": "($5)",

        @JsonProperty("is_applies")
        private boolean isApplies;   //": true
    }

    @Data
    public static class TaxVo{
        private BigDecimal amount;
        private String type;
        private BigDecimal fee;
    }

    @Data
    public static class DeliveryAddressVo{

        @JsonProperty("first_name")
        private String firstName;  //": "G",

        @JsonProperty("last_name")
        private String lastName;  //": "L",
        private String phone;  //": "91111113",

        @JsonProperty("postal_code")
        private String postalCode;  //": "",
        private String address;  //": "Geylang, Singapore",

        @JsonProperty("floor_number")
        private String floorNumber;  //": "#1-1234",
        private BigDecimal latitude;  //": 1.320054,
        private BigDecimal longitude;  //": 103.8918,

        @JsonProperty("timeslot_id")
        private String timeslotId;  //": "7cab4ff3-a7e5-470b-ace7-55ff8bdc9fb6",

        @JsonProperty("start_time")
        private String startTime;  //": "11:00:00",

        @JsonProperty("end_time")
        private String endTime;  //": "13:00:00"
    }


}
